﻿using System.ComponentModel.DataAnnotations;
using System.Text.Json.Serialization;
using WcMatch.Utility;

namespace WcMatch.Models
{
    public class RecruitmentApplication
    {
        [Key]
        public string Uid { get;set; }

        //单位名称
        public string? ComName { get; set; }

        //单位统一社会信用代码
        public string? ComId { get; set; }

        [JsonConverter(typeof(DateTimeJsonConverter))]
        public DateTime? CreatedAt { get; set; }

        public RecruitmentApplication(string? comName, string? comId)
        {
            Uid = Guid.NewGuid().ToString();
            ComName = comName;
            ComId = comId;
            CreatedAt = DateTime.Today;
        }
    }
}
